﻿@if (Request.IsAuthenticated)
{
    <div class="btn-group">
        <a class="btn btn-warning dropdown-toggle" data-toggle="dropdown" href="#"><i class="icon-user"></i>&nbsp;My Account
    <span class="caret"></span>
        </a>
        <ul class="dropdown-menu">
            <li>@Html.ActionLink(User.Identity.Name, "Manage", "Account", routeValues: null, htmlAttributes: new { title = "Manage" })</li>
            <li class="divider"></li>
            @using (Html.BeginForm("LogOff", "Account", FormMethod.Post, new { id = "logoutForm" }))
    {
    @Html.AntiForgeryToken()
                <li><a href="javascript:document.getElementById('logoutForm').submit()">Log off</a></li>
                }
        </ul>
    </div>
}
else
{
    @Html.ActionLink("Register", "Register", "Account", routeValues: null, htmlAttributes: new { id = "registerLink" }) <text> | </text>
    @Html.ActionLink("Log in", "Login", "Account", routeValues: null, htmlAttributes: new { id = "loginLink" })
    
}